package model.general;

import java.awt.Rectangle;

public class Location{
	private int x,y;

	public Location(int x, int y) {
		super();
		this.x = x;
		this.y = y;
	}

	public int getX() {
		return x;
	}

	public void setX(int x) {
		this.x = x;
	}

	public int getY() {
		return y;
	}

	public void setY(int y) {
		this.y = y;
	}
	
	public Rectangle getBounds(int width, int height){
		return new Rectangle(x,y,width,height);
	}
	
	public void increaseX(int distance){
		x += distance;
	}
	
	public void decreaseX(int distance){
		x -= distance;
	}
	
	public void increaseY(int distance){
		y += distance;
	}
	
	public void decreaseY(int distance){
		y -= distance;
	}

	@Override
	public String toString(){
		return "Location["+x+", " +y+"]";
	}
	
}
